<?php

class WishesModel extends AbstractModel
{

    protected $_comments;

    protected function _init()
    {
	
    }

    public function setComments($comments)
    {
	$this->_comments = $comments;
    }

    public function getComments()
    {
	return $this->_comments;
    }

    public function getViewLink($hash = null)
    {
	if ($this->getId()) {
	    $params = array('id' => $this->getId());
	    if ($hash) {
		$params['#'] = $hash;
	    }
	    return Yii::app()->createUrl('wishes/view', $params);
	}
	return false;
    }

}